import React from 'react';
import { Message, Card, Modal, Input, Button, Row, Col, Space } from 'antd';

import styles from './style.module.scss';
import Beian from 'components/Beian';
import WebsiteName from 'components/WebsiteName';
import Navigate from 'components/Navigate';
import service from 'service';
import Home, { HomeContext } from './context';

export default function AccountTheme(props) {
    const value = Home();
    const {
        user,
        list,
        getLabels,
        getList,
        editHandle,
        viewPassHandle,
        viewMoreHandle,
        searchText, setSearchText
    } = value;
    return (
        <HomeContext.Provider value={value}>
            <div className={styles.wrapper}>
                <div className={styles.header}>
                    <div className={styles.spaceBetween}>
                        <div className={styles.title}>
                            <WebsiteName />
                        </div>
                        <div className={styles.extra}>
                            <Navigate />
                        </div>
                    </div>
                </div>
                <div className={styles.container}>
                    <div className={styles.bar}>
                        <div className={styles.barContent}></div>
                        <div className={styles.footer}>
                            <Beian />
                        </div>
                    </div>
                    <div className={styles.content}>
                        <div className={styles.navBar}>
                            <div className={styles.spaceBetween}>
                                <div className={styles.title}>

                                </div>
                                <div className={styles.extra}>
                                    <Space>
                                        <Input.Search
                                            placeholder="输入关键字检索"
                                            style={{ width: 240 }}
                                            value={searchText}
                                            onChange={(e) => setSearchText(e.target.value)}
                                            onSearch={setSearchText} />
                                        <Button type="primary" onClick={(e) => editHandle(true, 'add', null)}>添加</Button>
                                        {/* <Link to="/batchAdd"><Button type="primary">批量添加</Button></Link>
                                        <ImportFile />

                                        <Button type="danger">批量删除</Button> */}
                                    </Space>
                                </div>
                            </div>
                        </div>
                        <div className={styles.list}>1</div>
                    </div>
                </div>
            </div>
        </HomeContext.Provider>
    )
}